package Gabor.servlet;

/**
 * Created with IntelliJ IDEA.
 * User: x
 * Date: 2012.10.10.
 * Time: 17:01
 * To change this template use File | Settings | File Templates.
 */

import Gabor.hibernate.TestExceptions;

import javax.servlet.ServletException;
import javax.servlet.http.HttpServlet;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;
import java.io.IOException;
import java.io.PrintWriter;

public class GaborServlet extends HttpServlet {

    public void doGet(HttpServletRequest req, HttpServletResponse res)
            throws ServletException, IOException {

        res.setContentType("text/html");
        PrintWriter out = res.getWriter();

        out.println("<HTML>");
        out.println("<HEAD><TITLE>Hello World</TITLE></HEAD>");
        out.println("<BODY>");
        TestExceptions testExceptions = new TestExceptions();
        out.println(testExceptions.getUserCount());
//        for(Object name : testExceptions.getUserNames()) {
//          out.println((String) name);
//        }
        out.println("<BIG>Hello World</BIG>");
        out.println("</BODY></HTML>");
    }
}